package org.example.ims.Service.Order;

import org.example.ims.Entity.Order.TransferDetail;
import org.springframework.data.domain.Page;

import java.util.List;

public interface TransferDetailService {

    TransferDetail createDetail(TransferDetail detail);
    TransferDetail updateDetail(Integer detailId, TransferDetail detail);
    void deleteDetail(Integer detailId);
    TransferDetail getDetailById(Integer detailId);
    Page<TransferDetail> getAllDetails(Integer page, Integer size);
    Page<TransferDetail> searchDetails(Integer orderId, Integer productId, Integer fromWarehouseId, Integer toWarehouseId, Integer page, Integer size);
    Page<TransferDetail> getDetailsByOrderId(Integer orderId, Integer page, Integer size);
    <T> List<T> convertOrderDetails(List<TransferDetail> details, Class<T> targetClass)throws Exception;
}